// 左侧菜单栏
function leftMenu(){
  let liA=doca('.l-list').children;
//   console.log(liA);
  for(let i=0;i<liA.length;i++){
   
     liA[i].onmouseover=function(){
       this.style.background='#ff6700';
       doca('.child-list').style.display='block'
      }
      liA[i].onmouseout=function(){
     this.style.background='';
     doca('.child-list').style.display='none'
       }
      
  }
}
leftMenu()
//导航下拉栏
function nav(){
  doca('.xiaomishouji').onmouseover=function(){
    doca('.down-menu-wrapper').style.display='block'
  }
  doca('.xiaomishouji').onmouseout=function(){
    doca('.down-menu-wrapper').style.display='none'
   
  }
  doca('.hongmi').onmouseover=function(){
    doca('.hongmi .down-menu-wrapper').style.display='block'
  }
  doca('.hongmi').onmouseout=function(){
    doca('.hongmi .down-menu-wrapper').style.display='none'
  }
doca('.television').onmouseover=function(){
  doca('.television .down-menu-wrapper').style.display='block'
}
doca('.television').onmouseout=function(){
  doca('.television .down-menu-wrapper').style.display='none'
}
doca('.notebook').onmouseover=function(){
  doca('.notebook .down-menu-wrapper').style.display='block'
}
doca('.notebook').onmouseout=function(){
  doca('.notebook .down-menu-wrapper').style.display='none'
}
doca('.flat').onmouseover=function(){
  doca('.flat .down-menu-wrapper').style.display='block'
}
doca('.flat').onmouseout=function(){
  doca('.flat .down-menu-wrapper').style.display='none'
}
doca('.hea').onmouseover=function(){
  doca('.hea .down-menu-wrapper').style.display='block'
}
doca('.hea').onmouseout=function(){
  doca('.hea .down-menu-wrapper').style.display='none'
}
doca('.Router').onmouseover=function(){
  doca('.Router .down-menu-wrapper').style.display='block'
}
doca('.Router').onmouseout=function(){
  doca('.Router .down-menu-wrapper').style.display='none'
}
doca('.Hardware').onmouseover=function(){
  doca('.Hardware .down-menu-wrapper').style.display='block'
}
doca('.Hardware').onmouseout=function(){
  doca('.Hardware .down-menu-wrapper').style.display='none'
}

}

nav();




 async function getLogin(){
  //

  // 注册的数据
  let goods=await axios.get({url:'http://localhost:53000/course1'})
 goods.forEach(item=>{
 
 })

docall('li').forEach(item=>{
item.onclick=function(){
 location.href='./goodsList.html'
}
})
}
getLogin()
// 获取节点方法
function doca (ele){
    return document.querySelector(ele)
}
function docall (ele){
    return document.querySelectorAll(ele)
   
}

